package com.hrm.service;

import com.hrm.dto.EmpDepDTO;
import com.hrm.dto.StaffPercentBySex;
import com.hrm.dto.StarffPercentByDepartment;
import com.hrm.entity.Employee;
import com.hrm.utils.EmailVerifyCode;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import java.util.List;

/**
 * @Auther:
 * @Date: 2020/5/20 09:54
 * @Description:
 */
public interface EmployeeService {

    /**
     * 检查用户名是否存在
     * @param employee
     * @return 如果存在返回false,不存哎返回true
     */
    boolean checkName(Employee employee);

    boolean checkPhone(Employee employee);

    boolean checkEmail(Employee employee);

    Employee loginCheck(Employee employee);

    boolean Registe(Employee employee);

    EmailVerifyCode sendCodeToEmail(String email);

    boolean emailCodeTest(String code, HttpSession session);

    boolean resetPwd(Employee employee);

    String uploadIcon(MultipartFile file, HttpServletRequest request,Integer id);

    boolean setInfo(Employee employee);

    boolean modifyEmail(Employee employee);

    void updateSession(HttpSession session,Integer id);

    List<EmpDepDTO> empDepList();

    List<String> jobTitleList();

    List<EmpDepDTO> queryEmpDepByName(Employee employee);

    boolean updateEmp(Employee employee);

    long countEmp(Integer deptId);

    List<EmpDepDTO> queryEmpDepByDepId(Integer deptId);

    List<Employee> unEmployeeList();

    boolean deleteUnEmp(Integer id);

    StaffPercentBySex staffPercent();

    List<StarffPercentByDepartment> staffPercentByDepartment();


}
